import {NgModule} from '@angular/core';
import {RouterModule, Routes} from '@angular/router';
import {MySqlComponent} from "./my-sql/my-sql.component";
import {SqlEditComponent} from "./sql-edit/sql-edit.component";
import {SqlManagementComponent} from "./sql-management/sql-management.component";
import {SqlPreviewComponent} from "./sql-preview/sql-preview.component";
import {ExportSqlComponent} from "./export-sql/export-sql.component";

const routes: Routes = [{
  path: 'mine',
  component: MySqlComponent,
  data: {
    keep: true
  }
}, {
  path: 'mine/edit',
  component: SqlEditComponent
}, {
  path: 'all',
  component: SqlManagementComponent,
  data: {
    keep: true
  }
}, {
  path: 'all/preview',
  component: SqlPreviewComponent
}, {
  path: 'export',
  component: ExportSqlComponent
}];

@NgModule({
  imports: [RouterModule.forChild(routes)],
  exports: [RouterModule]
})
export class SqlRoutingModule {
}
